package io.fft.flight.modules.flight.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import io.fft.flight.common.service.impl.CrudServiceImpl;
import io.fft.flight.modules.flight.dao.OrderPriceDao;
import io.fft.flight.modules.flight.dto.OrderPriceDTO;
import io.fft.flight.modules.flight.entity.OrderPriceEntity;
import io.fft.flight.modules.flight.service.OrderPriceService;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;

import java.util.Map;

/**
 * 订单价格明细
 *
 * @author likailun kellenli30541@gmail.com
 * @since 1.0.0 2024-06-19
 */
@Service
public class OrderPriceServiceImpl extends CrudServiceImpl<OrderPriceDao, OrderPriceEntity, OrderPriceDTO> implements OrderPriceService {

    @Override
    public QueryWrapper<OrderPriceEntity> getWrapper(Map<String, Object> params){
        String id = (String)params.get("id");

        QueryWrapper<OrderPriceEntity> wrapper = new QueryWrapper<>();
        wrapper.eq(StringUtils.isNotBlank(id), "id", id);

        return wrapper;
    }


}